-- GENERATED SPELL FOR [Deranged Helboar] --


function spell0_16863(pUnit, Event) --@Enrage,Self--
pUnit:FullCastSpellOnTarget(8599,pUnit)
pUnit:RegisterEvent('Sorts_16863', 689, 1)
end

function spell1_16863(pUnit, Event) --@Tell dog I just died!,n/a--
pUnit:FullCastSpellOnTarget(37689,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_16863', 617, 1)
end

function Sorts_16863(pUnit, Event)
local choix_sorts_16863 = math.random(0, 1)
if choix_sorts_16863 == 0 then
pUnit:RegisterEvent('spell0_16863', 1, 1)
end
if choix_sorts_16863 == 1 then
pUnit:RegisterEvent('spell1_16863', 1, 1)
end
end

function mob16863_Action(pUnit, Event)
pUnit:RegisterEvent('Sorts_16863', math.random(1500, 3000), 1)
end

function mob16863_Leave(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob16863_Kill(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob16863_Die(pUnit, Event)
pUnit:RemoveEvents();
end

RegisterUnitEvent(16863, 1, 'mob16863_Action')
RegisterUnitEvent(16863, 2, 'mob16863_Leave')
RegisterUnitEvent(16863, 3, 'mob16863_Kill')
RegisterUnitEvent(16863, 4, 'mob16863_Die')
